define([
    "app"
],function (app) {
    app.service("manageTeacherDataService",[
        "$http",
        function ($http) {
            return {
                // 查询所有的导师
                getAllTeacher:function () {
                    return $http
                        .get(requestRootUrl + "api/manage-teacher/all-teacher");
                },
                // 添加一个导师
                addTeacher:function (teacher) {
                    return $http
                        .post(requestRootUrl + "api/manage-teacher/add-teacher",teacher);
                },
                // 修改一个导师
                updateTeacher:function (teacher) {
                    return $http
                        .post(requestRootUrl + "api/manage-teacher/update-teacher",teacher);
                },
                // 删除一个导师
                deleteTeacher:function (teacher) {
                    return $http
                        .post(requestRootUrl + " api/manage-teacher/delete-teacher",teacher);
                }
            }
        }
    ])
});